<script>
	import {
		getToken,
	} from '@/common/auth.js'
	export default {
		globalData: { //全局变量
			//公共底部
			common_bottom: [{
					iconPath: "/static/tab/index.png",
					selectedIconPath: "/static/tab/index1.png",
					text: '消息',
					customIcon: false,
					pagePath: "/pages/index/index"
				},
				{
					iconPath: "/static/tab/shuimian.png",
					selectedIconPath: "/static/tab/shuimian1.png",
					text: '工作台',
					customIcon: false,
					pagePath: "/pages/work/work"
				},
				{
					iconPath: "/static/tab/community.png",
					selectedIconPath: "/static/tab/community1.png",
					text: '云文档',
					customIcon: false,
					pagePath: "/pages/document/document"
				},
				{
					iconPath: "/static/tab/user.png",
					selectedIconPath: "/static/tab/user1.png",
					text: '通讯录',
					customIcon: false,
					pagePath: "/pages/user/user"
				},
			],
			AppinnerAudioContext: null,
		},
		onLaunch: function() {
			var token = getToken()
			
		},
		onShow: function(option) {
			console.log('App Show')
			this.autoUpdate()
			if (option.query.scene && this.getText(option.query.scene)) {
				let ops = this.getOption(decodeURIComponent(option.query.scene))
				uni.setStorageSync("parentId", ops.parentId)
				console.log(ops, "ops")
			}
			console.log(option)
			if (option.query.UserId && this.getText(option.query.UserId)) {
				uni.setStorageSync("parentId", option.query.UserId)
			}
			var token = getToken()
			console.log('token',token)
			if(!token){
				// console.log('我进来了')
				uni.reLaunch({
					url:'/pages2/pages/login/login'
				});
			}
			
			
			this.globalData.AppinnerAudioContext = uni.createInnerAudioContext();
		},
		onHide: function() {
			console.log('App Hide')
		},
		methods: {
			
		}
	}
</script>

<style lang="less">
   /* 假设字体文件名为 MyFont.woff，并放在 static/fonts 文件夹下 */
   @font-face {
     font-family: 'MyFont'; /* 你可以给字体起一个别名 */
     src: url('~@/static/fonts/SourceHanSansCN-Regular.otf') format('off'); /* 注意路径可能需要根据你的项目结构进行调整 */
          // url('~@/static/fonts/MyFont.woff2') format('woff2'), /* 如果有 woff2 版本也可以加上 */
          // url('~@/static/fonts/MyFont.ttf') format('truetype'); /* 还可以加上 ttf 格式作为备选 */
     font-weight: normal;
     font-style: normal;
   }

	.scroll-view_H {
		white-space: nowrap;
		width: 100%;
	}

	.empty {
		position: absolute;
		left: 50%;
		top: 50%;
		transform: translate(-50%, -50%);
		height: initial !important;
	}

	.emptyto .u-empty {
		padding-top: 10% !important;
	}


	.padding32env {
		padding-bottom: calc(32rpx + env(safe-area-inset-bottom)) !important;
	}

	.bofangqienv {
		padding-bottom: calc(162rpx + env(safe-area-inset-bottom)) !important;
	}

	.paddingenv {
		padding-bottom: env(safe-area-inset-bottom);
	}

	.submitPadding {
		padding-bottom: calc(120rpx + env(safe-area-inset-bottom));
	}

	.margin032 {
		margin: 0 32rpx;
	}


	.absolutenavbar {
		position: absolute;
	}

	.bordernone {
		border: none !important;
	}
	.movablearea {
		position: fixed;
		right: 120rpx;
		top: 50%;
		width: 0;
		z-index: 222;
		transform: translate(0, -50%);
		.movableview {
			width: 88rpx;
			height: 88rpx;
	
			.kefubtn {
				background: none;
				background-color: none;
				width: 88rpx;
				height: 88rpx;
				overflow: hidden;
				border-radius: 50%;
				box-shadow: 0 0 8rpx #999;
			}
		}
	}
</style>
<style lang="scss">
	/* 注意要写在第一行，同时给style标签加入lang="scss"属性 */
	@import "uview-ui/index.scss";

	ol {
		margin: 0 32rpx;
	}

	// image {
	// 	width: 100%;
	// 	height: 100%;
	// }

	* {
		padding: 0;
		margin: 0;
	}

	.allwrap {
		width: 686rpx !important;
		margin: 0 auto;
	}

	.flexal {
		display: flex;
		align-items: center;
	}

	.flexcen {
		display: flex;
		align-items: center;
		justify-content: center;
	}

	.flexspb {
		display: flex;
		align-items: center;
		justify-content: space-between;
	}

	.flexcum {
		display: flex;
		flex-direction: column;
	}
	
	.flexcumal {
		display: flex;
		flex-direction: column;
		align-items: center;
	}
	

	button::after {
		border: none;
	}

	button {
		padding: 0;
		margin: 0;
	}

	/deep/.u-tabbar__content {
		box-shadow: 0rpx 1rpx 21rpx 1rpx rgba(0, 0, 0, 0.2);
	}

	.flexwrap {
		flex-wrap: wrap;
	}

	.text-1 {
		overflow: hidden;
		word-break: break-all;
		text-overflow: ellipsis;
		display: -webkit-box;
		-webkit-box-orient: vertical;
		-webkit-line-clamp: 1;
	}

	.text-2 {
		-webkit-line-clamp: 2;
	}

	.bottFix {
		position: fixed;
		bottom: 0;
		left: 0;
		z-index: 99;
		background-color: #FFFFFF;
	}

	.del {
		text-decoration: line-through;
		color: #999999;
	}

	.br5 {
		overflow: hidden;
		border-radius: 50%;
	}

	.fal {
		align-items: stretch;
	}

	.jue {
		position: absolute;
		left: 0;
		top: 0;
	}

	.xiang {
		position: relative;
		z-index: 1;
	}

	.allbutton {
		padding: 0;
		background-color: initial;
		margin: 0;
		line-height: initial;
		overflow: initial;
		box-sizing: initial;
		font-size: initial;
	}

	.allbutton::after {
		content: none;
	}

	.flexalign {
		display: flex;
		align-items: center;
	}
	.flexcolumnalign {
		display: flex;
		flex-direction: column;
		align-items: center;
	}

	.flexcenter {
		display: flex;
		justify-content: center;
		align-items: center;
	}

	.flexbetween {
		display: flex;
		justify-content: space-between;
		align-items: center;
	}

	.flexaround {
		display: flex;
		justify-content: space-around;
		align-items: center;
	}

	.flexevenly {
		display: flex;
		justify-content: space-evenly;
		align-items: center;
	}

	.flexdirection {
		display: flex;
		flex-direction: column;
		justify-content: center;
		align-items: center;
	}

	.flexshrink {
		flex-shrink: 0;
	}

	.marginbtm0 {
		margin-bottom: 0 !important;
	}

	scroll-view ::-webkit-scrollbar {
		display: none !important;
		width: 0 !important;
		height: 0 !important;
		-webkit-appearance: none;
		background: transparent;
	}

	.shangchengBg {
		background: linear-gradient(180deg, #3470AD 0%, #003460 100%) !important;
	}

	// uni-page-body,
	// html,
	// body {
	// 	height: 100%;
	// }
	page>view {
		// background: linear-gradient(180deg, #3470AD 0%, #003460 100%) no-repeat 100% 100%;
		background: #FEFEFE;
		min-height: 100vh;
		
	}

	page {
		// background: linear-gradient(180deg, #3470AD 0%, #003460 100%) no-repeat 100% 100%;
		background: #FEFEFE;
		
	}

	.bgmohu {
		background-color: #437BB1 !important;
	}

	.bgmohu2 {
		background-color: #437BB1 !important;
	}

	.monfh {
		font-size: 26rpx;
		color: #71DDFF;
	}

	.borderbtmfff03 {
		border-bottom: 1rpx solid rgba(255, 255, 255, 0.3);
	}

	.bg008FD7 {
		background-color: #008FD7 !important;
	}

	.bginitial {
		background-color: initial !important;
	}

	.colorfff {
		color: #fff !important;
	}

	.zIndex10 {
		position: relative;
		z-index: 10;
	}

	.zIndex30 {
		position: relative;
		z-index: 30;
	}

	.zIndex50 {
		position: relative;
		z-index: 50;
	}

	.lineclamp1 {
		overflow: hidden;
		word-break: break-all; //宽度够 不会提前出现省略号
		text-overflow: ellipsis;
		display: -webkit-box; //变成块状
		-webkit-box-orient: vertical;
		-webkit-line-clamp: 1;
	}
	.line-ellipsis{
		white-space: nowrap; /* 不换行 */
		overflow: hidden; /* 隐藏超出内容 */
		text-overflow: ellipsis; /* 用省略号表示超出部分 */
	}

	.flexshrinkNo {
		flex-shrink: initial !important;
	}
	
</style>


<!-- codefun公用样式 -->

<style>
	/************************************************************
	  ** 请将全局样式拷贝到项目的全局 CSS 文件或者当前页面的顶部 **
	  ** 否则页面将无法正常显示                                  **
	  ************************************************************/

	html {
		font-size: 16px;
	}

	body {
		margin: 0;
		font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans',
			'Droid Sans', 'Helvetica Neue', 'Microsoft Yahei', sans-serif;
		-webkit-font-smoothing: antialiased;
		-moz-osx-font-smoothing: grayscale;
	}

	view,
	image,
	text {
		box-sizing: border-box;
		flex-shrink: 0;
		/* font-family: PingFang SC; */
		font-family: 'MyFont', sans-serif;
	}

	#app {
		width: 100vw;
		height: 100vh;
	}

	.flex-row {
		display: flex;
		flex-direction: row;
	}

	.flex-col {
		display: flex;
		flex-direction: column;
	}

	.justify-start {
		justify-content: flex-start;
	}

	.justify-end {
		justify-content: flex-end;
	}

	.justify-center {
		justify-content: center;
	}

	.justify-between {
		justify-content: space-between;
	}

	.justify-around {
		justify-content: space-around;
	}

	.justify-evenly {
		justify-content: space-evenly;
	}

	.items-start {
		align-items: flex-start;
	}

	.items-end {
		align-items: flex-end;
	}

	.items-center {
		align-items: center;
	}

	.items-baseline {
		align-items: baseline;
	}

	.items-stretch {
		align-items: stretch;
	}

	.self-start {
		align-self: flex-start;
	}

	.self-end {
		align-self: flex-end;
	}

	.self-center {
		align-self: center;
	}

	.self-baseline {
		align-self: baseline;
	}

	.self-stretch {
		align-self: stretch;
	}

	.flex-1 {
		flex: 1 1 0%;
	}

	.flex-auto {
		flex: 1 1 auto;
	}

	.grow {
		flex-grow: 1;
	}

	.grow-0 {
		flex-grow: 0;
	}

	.shrink {
		flex-shrink: 1;
	}

	.shrink-0 {
		flex-shrink: 0;
	}

	.relative {
		position: relative;
	}

	.ml-2 {
		margin-left: 4rpx;
	}

	.mt-2 {
		margin-top: 4rpx;
	}

	.ml-4 {
		margin-left: 8rpx;
	}

	.mt-4 {
		margin-top: 8rpx;
	}

	.ml-6 {
		margin-left: 12rpx;
	}

	.mt-6 {
		margin-top: 12rpx;
	}

	.ml-8 {
		margin-left: 16rpx;
	}

	.mt-8 {
		margin-top: 16rpx;
	}

	.ml-10 {
		margin-left: 20rpx;
	}

	.mt-10 {
		margin-top: 20rpx;
	}

	.ml-12 {
		margin-left: 24rpx;
	}

	.mt-12 {
		margin-top: 24rpx;
	}

	.ml-14 {
		margin-left: 28rpx;
	}

	.mt-14 {
		margin-top: 28rpx;
	}

	.ml-16 {
		margin-left: 32rpx;
	}

	.mt-16 {
		margin-top: 32rpx;
	}

	.ml-18 {
		margin-left: 36rpx;
	}

	.mt-18 {
		margin-top: 36rpx;
	}

	.ml-20 {
		margin-left: 40rpx;
	}

	.mt-20 {
		margin-top: 40rpx;
	}

	.ml-22 {
		margin-left: 44rpx;
	}

	.mt-22 {
		margin-top: 44rpx;
	}

	.ml-24 {
		margin-left: 48rpx;
	}

	.mt-24 {
		margin-top: 48rpx;
	}

	.ml-26 {
		margin-left: 52rpx;
	}

	.mt-26 {
		margin-top: 52rpx;
	}

	.ml-28 {
		margin-left: 56rpx;
	}

	.mt-28 {
		margin-top: 56rpx;
	}

	.ml-30 {
		margin-left: 60rpx;
	}

	.mt-30 {
		margin-top: 60rpx;
	}

	.ml-32 {
		margin-left: 64rpx;
	}

	.mt-32 {
		margin-top: 64rpx;
	}

	.ml-34 {
		margin-left: 68rpx;
	}

	.mt-34 {
		margin-top: 68rpx;
	}

	.ml-36 {
		margin-left: 72rpx;
	}

	.mt-36 {
		margin-top: 72rpx;
	}

	.ml-38 {
		margin-left: 76rpx;
	}

	.mt-38 {
		margin-top: 76rpx;
	}

	.ml-40 {
		margin-left: 80rpx;
	}

	.mt-40 {
		margin-top: 80rpx;
	}

	.ml-42 {
		margin-left: 84rpx;
	}

	.mt-42 {
		margin-top: 84rpx;
	}

	.ml-44 {
		margin-left: 88rpx;
	}

	.mt-44 {
		margin-top: 88rpx;
	}

	.ml-46 {
		margin-left: 92rpx;
	}

	.mt-46 {
		margin-top: 92rpx;
	}

	.ml-48 {
		margin-left: 96rpx;
	}

	.mt-48 {
		margin-top: 96rpx;
	}

	.ml-50 {
		margin-left: 100rpx;
	}

	.mt-50 {
		margin-top: 100rpx;
	}

	.ml-52 {
		margin-left: 104rpx;
	}

	.mt-52 {
		margin-top: 104rpx;
	}

	.ml-54 {
		margin-left: 108rpx;
	}

	.mt-54 {
		margin-top: 108rpx;
	}

	.ml-56 {
		margin-left: 112rpx;
	}

	.mt-56 {
		margin-top: 112rpx;
	}

	.ml-58 {
		margin-left: 116rpx;
	}

	.mt-58 {
		margin-top: 116rpx;
	}

	.ml-60 {
		margin-left: 120rpx;
	}

	.mt-60 {
		margin-top: 120rpx;
	}

	.ml-62 {
		margin-left: 124rpx;
	}

	.mt-62 {
		margin-top: 124rpx;
	}

	.ml-64 {
		margin-left: 128rpx;
	}

	.mt-64 {
		margin-top: 128rpx;
	}

	.ml-66 {
		margin-left: 132rpx;
	}

	.mt-66 {
		margin-top: 132rpx;
	}

	.ml-68 {
		margin-left: 136rpx;
	}

	.mt-68 {
		margin-top: 136rpx;
	}

	.ml-70 {
		margin-left: 140rpx;
	}

	.mt-70 {
		margin-top: 140rpx;
	}

	.ml-72 {
		margin-left: 144rpx;
	}

	.mt-72 {
		margin-top: 144rpx;
	}

	.ml-74 {
		margin-left: 148rpx;
	}

	.mt-74 {
		margin-top: 148rpx;
	}

	.ml-76 {
		margin-left: 152rpx;
	}

	.mt-76 {
		margin-top: 152rpx;
	}

	.ml-78 {
		margin-left: 156rpx;
	}

	.mt-78 {
		margin-top: 156rpx;
	}

	.ml-80 {
		margin-left: 160rpx;
	}

	.mt-80 {
		margin-top: 160rpx;
	}

	.ml-82 {
		margin-left: 164rpx;
	}

	.mt-82 {
		margin-top: 164rpx;
	}

	.ml-84 {
		margin-left: 168rpx;
	}

	.mt-84 {
		margin-top: 168rpx;
	}

	.ml-86 {
		margin-left: 172rpx;
	}

	.mt-86 {
		margin-top: 172rpx;
	}

	.ml-88 {
		margin-left: 176rpx;
	}

	.mt-88 {
		margin-top: 176rpx;
	}

	.ml-90 {
		margin-left: 180rpx;
	}

	.mt-90 {
		margin-top: 180rpx;
	}

	.ml-92 {
		margin-left: 184rpx;
	}

	.mt-92 {
		margin-top: 184rpx;
	}

	.ml-94 {
		margin-left: 188rpx;
	}

	.mt-94 {
		margin-top: 188rpx;
	}

	.ml-96 {
		margin-left: 192rpx;
	}

	.mt-96 {
		margin-top: 192rpx;
	}

	.ml-98 {
		margin-left: 196rpx;
	}

	.mt-98 {
		margin-top: 196rpx;
	}

	.ml-100 {
		margin-left: 200rpx;
	}

	.mt-100 {
		margin-top: 200rpx;
	}
</style>